<?php
namespace app\api\validate;
use think\Validate;
class Login extends Validate{

    protected $rule = [
        'phone'  =>  'require',
        'password' =>  'require',
        're_password' => 'require',
    ];

    protected $message = [
        'phone.require'  =>  PHONE_CANNOT_EMPTY,
        'password.require' =>  PASSWORD_CONNOT_EMPTTY,
        're_password.require' =>RE_INPUT_PASSWORD,
    ];
    protected $scene = [
        'register'   =>  ['phone','password','re_password'],
        'login'  =>  ['phone','password'],
    ];
}